<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@include file="common/taglib.jsp" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE html>
<html>
  <head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>我的首页</title>
	<meta http-equiv="X-UA-Compatible" content="IE=11; IE=10; IE=9; IE=8; IE=7; IE=EDGE">
	
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/header.css"/>">
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/common.css"/>">
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/public.css"/>">
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/default.css"/>">
	<link rel="stylesheet" type="text/css" href="<c:url value="/css/footer.css"/>">
	<script type="text/javascript" src="<c:url value="/js/jquery.min.js"/>"></script>
	<script type="text/javascript">
		function hotJob(){
			$.ajax({
				url:'<c:url value="/job/hotJob"/>',
				cache:false,
				type:'POST',
				dataType:'json',
				success:function(data){
					$.each(data,function(i,object){
						//alert("职位名称："+object[1])
						$('#hotjob').append(""+
						        "<ul>"+         
					        	"<li>"+
					              "<a target='_blank' href='<c:url value='/job/detail/"+object[0]+"'/>'>"+
					                "<h4>"+
					                  "<span title='"+object[1]+"' class='company-name'>"+object[1]+"</span>"+                                
									"</h4>"+
					                "<dl class='clearfix'>"+
					                  "<dt class='salary'><span class='muted'>年薪 </span><strong class='text-warning'>"+object[5]+"万</strong></dt>"+
					                  "<dt class='company'>"+object[2]+"</dt>"+
					                  "<dt class='city'><span class='muted'>"+object[3]+"</span></dt>"+
					                  "<dt class='date'><span class='muted'>"+object[4]+"</span></dt>"+
					                "</dl>"+
					              "</a>"+
					            "</li>"+       
					            "</ul>"+
								"");
					});
				}
			});
		}
	</script>
  </head>
<body id="home" onload="hotJob()">

<jsp:include page="common/header.jsp"></jsp:include>

<div class="wrap clearfix">
  <div class="main"> 
   <div class="feeds-panel">
    <div class="tabs-ui tabs-ui-main">
      <ul>
        <li class="current">推荐职位</li>
      </ul>
    </div>
    <div class="feeds">
	<div id="feed-recommendjob-feed-list" class="feed-recommend-job">
      <div class="feed-list" id="hotjob">
      </div>
      <div class="notice-box">
        <p>不满意这些职位？您可以<a href="<c:url value="/job/search"/>">寻找更多职位</a></p>
      </div> 
	</div>
	</div>
  </div>
</div>

</div>

<jsp:include page="common/footer.jsp"></jsp:include>

</body>
</html>
